/*******************************************************************************
 * Copyright (c) 2008 Sylvain Sicard.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the GNU Lesser Public License v2.1
 * which accompanies this distribution, and is available at
 * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
 * 
 * Contributors:
 *     Sylvain Sicard - initial API and implementation
 ******************************************************************************/
package fr.jade.console.core;

import java.util.HashMap;
import java.util.Map;
import java.util.Set;


public class Environment {
	
	protected Map<String, Object> vars;
	
	public Environment(){
		this.vars = new HashMap<String, Object>();
	}
	
	public Object getEnvVar(String key) {
		return vars.get(key);
	}

	public void setEnvVar(String key, Object value) {
		this.vars.put(key, value);
	}
	
	public Set<String> listEnvVar(){
	  return vars.keySet();
	}
	
	public boolean isSetEnvVar(String key){
    return vars.containsKey(key);
  }
}
